3.3.69 \(\int \frac {\sec ^2(e+f x)}{\sqrt {a+b \sec (e+f x)} \sqrt {c+d \sec (e+f x)}} \, dx\) [269]

3.3.69.1 Optimal result
3.3.69.2 Mathematica [C] (warning: unable to verify)
3.3.69.3 Rubi [A] (verified)
3.3.69.4 Maple [A] (verified)
3.3.69.5 Fricas [F(-1)]
3.3.69.6 Sympy [F]
3.3.69.7 Maxima [F]
3.3.69.8 Giac [F]
3.3.69.9 Mupad [F(-1)]

3.3.69.1 Optimal result

Integrand size = 37, antiderivative size = 396 \[ \int \frac {\sec ^2(e+f x)}{\sqrt {a+b \sec (e+f x)} \sqrt {c+d \sec (e+f x)}} \, dx=\frac {2 \cot (e+f x) \operatorname {EllipticPi}\left (\frac {b (c+d)}{(a+b) d},\arcsin \left (\frac {\sqrt {\frac {a+b}{c+d}} \sqrt {c+d \sec (e+f x)}}{\sqrt {a+b \sec (e+f x)}}\right ),\frac {(a-b) (c+d)}{(a+b) (c-d)}\right ) \sqrt {-\frac {(b c-a d) (1-\sec (e+f x))}{(c+d) (a+b \sec (e+f x))}} \sqrt {\frac {(b c-a d) (1+\sec (e+f x))}{(c-d) (a+b \sec (e+f x))}} (a+b \sec (e+f x))}{b d \sqrt {\frac {a+b}{c+d}} f}-\frac {2 a \sqrt {a+b} \cot (e+f x) \operatorname {EllipticF}\left (\arcsin \left (\frac {\sqrt {c+d} \sqrt {a+b \sec (e+f x)}}{\sqrt {a+b} \sqrt {c+d \sec (e+f x)}}\right ),\frac {(a+b) (c-d)}{(a-b) (c+d)}\right ) \sqrt {\frac {(b c-a d) (1-\sec (e+f x))}{(a+b) (c+d \sec (e+f x))}} \sqrt {-\frac {(b c-a d) (1+\sec (e+f x))}{(a-b) (c+d \sec (e+f x))}} (c+d \sec (e+f x))}{b \sqrt {c+d} (b c-a d) f} \]

output
2*cot(f*x+e)*EllipticPi(((a+b)/(c+d))^(1/2)*(c+d*sec(f*x+e))^(1/2)/(a+b*se 
c(f*x+e))^(1/2),b*(c+d)/(a+b)/d,((a-b)*(c+d)/(a+b)/(c-d))^(1/2))*(a+b*sec( 
f*x+e))*(-(-a*d+b*c)*(1-sec(f*x+e))/(c+d)/(a+b*sec(f*x+e)))^(1/2)*((-a*d+b 
*c)*(1+sec(f*x+e))/(c-d)/(a+b*sec(f*x+e)))^(1/2)/b/d/f/((a+b)/(c+d))^(1/2) 
-2*a*cot(f*x+e)*EllipticF((c+d)^(1/2)*(a+b*sec(f*x+e))^(1/2)/(a+b)^(1/2)/( 
c+d*sec(f*x+e))^(1/2),((a+b)*(c-d)/(a-b)/(c+d))^(1/2))*(c+d*sec(f*x+e))*(a 
+b)^(1/2)*((-a*d+b*c)*(1-sec(f*x+e))/(a+b)/(c+d*sec(f*x+e)))^(1/2)*(-(-a*d 
+b*c)*(1+sec(f*x+e))/(a-b)/(c+d*sec(f*x+e)))^(1/2)/b/(-a*d+b*c)/f/(c+d)^(1 
/2)
 
3.3.69.2 Mathematica [C] (warning: unable to verify)

Result contains complex when optimal does not.

Time = 36.53 (sec) , antiderivative size = 39359, normalized size of antiderivative = 99.39 \[ \int \frac {\sec ^2(e+f x)}{\sqrt {a+b \sec (e+f x)} \sqrt {c+d \sec (e+f x)}} \, dx=\text {Result too large to show} \]

input
Integrate[Sec[e + f*x]^2/(Sqrt[a + b*Sec[e + f*x]]*Sqrt[c + d*Sec[e + f*x] 
]),x]
 
output
Result too large to show
 
3.3.69.3 Rubi [A] (verified)

Time = 1.10 (sec) , antiderivative size = 396, normalized size of antiderivative = 1.00, number of steps used = 5, number of rules used = 5, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.135, Rules used = {3042, 4473, 3042, 4470, 4472}

Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.

\(\displaystyle \int \frac {\sec ^2(e+f x)}{\sqrt {a+b \sec (e+f x)} \sqrt {c+d \sec (e+f x)}} \, dx\)

\(\Big \downarrow \) 3042

\(\displaystyle \int \frac {\csc \left (e+f x+\frac {\pi }{2}\right )^2}{\sqrt {a+b \csc \left (e+f x+\frac {\pi }{2}\right )} \sqrt {c+d \csc \left (e+f x+\frac {\pi }{2}\right )}}dx\)

\(\Big \downarrow \) 4473

\(\displaystyle \frac {\int \frac {\sec (e+f x) \sqrt {a+b \sec (e+f x)}}{\sqrt {c+d \sec (e+f x)}}dx}{b}-\frac {a \int \frac {\sec (e+f x)}{\sqrt {a+b \sec (e+f x)} \sqrt {c+d \sec (e+f x)}}dx}{b}\)

\(\Big \downarrow \) 3042

\(\displaystyle \frac {\int \frac {\csc \left (e+f x+\frac {\pi }{2}\right ) \sqrt {a+b \csc \left (e+f x+\frac {\pi }{2}\right )}}{\sqrt {c+d \csc \left (e+f x+\frac {\pi }{2}\right )}}dx}{b}-\frac {a \int \frac {\csc \left (e+f x+\frac {\pi }{2}\right )}{\sqrt {a+b \csc \left (e+f x+\frac {\pi }{2}\right )} \sqrt {c+d \csc \left (e+f x+\frac {\pi }{2}\right )}}dx}{b}\)

\(\Big \downarrow \) 4470

\(\displaystyle \frac {2 \cot (e+f x) (a+b \sec (e+f x)) \sqrt {-\frac {(b c-a d) (1-\sec (e+f x))}{(c+d) (a+b \sec (e+f x))}} \sqrt {\frac {(b c-a d) (\sec (e+f x)+1)}{(c-d) (a+b \sec (e+f x))}} \operatorname {EllipticPi}\left (\frac {b (c+d)}{(a+b) d},\arcsin \left (\frac {\sqrt {\frac {a+b}{c+d}} \sqrt {c+d \sec (e+f x)}}{\sqrt {a+b \sec (e+f x)}}\right ),\frac {(a-b) (c+d)}{(a+b) (c-d)}\right )}{b d f \sqrt {\frac {a+b}{c+d}}}-\frac {a \int \frac {\csc \left (e+f x+\frac {\pi }{2}\right )}{\sqrt {a+b \csc \left (e+f x+\frac {\pi }{2}\right )} \sqrt {c+d \csc \left (e+f x+\frac {\pi }{2}\right )}}dx}{b}\)

\(\Big \downarrow \) 4472

\(\displaystyle \frac {2 \cot (e+f x) (a+b \sec (e+f x)) \sqrt {-\frac {(b c-a d) (1-\sec (e+f x))}{(c+d) (a+b \sec (e+f x))}} \sqrt {\frac {(b c-a d) (\sec (e+f x)+1)}{(c-d) (a+b \sec (e+f x))}} \operatorname {EllipticPi}\left (\frac {b (c+d)}{(a+b) d},\arcsin \left (\frac {\sqrt {\frac {a+b}{c+d}} \sqrt {c+d \sec (e+f x)}}{\sqrt {a+b \sec (e+f x)}}\right ),\frac {(a-b) (c+d)}{(a+b) (c-d)}\right )}{b d f \sqrt {\frac {a+b}{c+d}}}-\frac {2 a \sqrt {a+b} \cot (e+f x) (c+d \sec (e+f x)) \sqrt {\frac {(b c-a d) (1-\sec (e+f x))}{(a+b) (c+d \sec (e+f x))}} \sqrt {-\frac {(b c-a d) (\sec (e+f x)+1)}{(a-b) (c+d \sec (e+f x))}} \operatorname {EllipticF}\left (\arcsin \left (\frac {\sqrt {c+d} \sqrt {a+b \sec (e+f x)}}{\sqrt {a+b} \sqrt {c+d \sec (e+f x)}}\right ),\frac {(a+b) (c-d)}{(a-b) (c+d)}\right )}{b f \sqrt {c+d} (b c-a d)}\)

input
Int[Sec[e + f*x]^2/(Sqrt[a + b*Sec[e + f*x]]*Sqrt[c + d*Sec[e + f*x]]),x]
 
output
(2*Cot[e + f*x]*EllipticPi[(b*(c + d))/((a + b)*d), ArcSin[(Sqrt[(a + b)/( 
c + d)]*Sqrt[c + d*Sec[e + f*x]])/Sqrt[a + b*Sec[e + f*x]]], ((a - b)*(c + 
 d))/((a + b)*(c - d))]*Sqrt[-(((b*c - a*d)*(1 - Sec[e + f*x]))/((c + d)*( 
a + b*Sec[e + f*x])))]*Sqrt[((b*c - a*d)*(1 + Sec[e + f*x]))/((c - d)*(a + 
 b*Sec[e + f*x]))]*(a + b*Sec[e + f*x]))/(b*d*Sqrt[(a + b)/(c + d)]*f) - ( 
2*a*Sqrt[a + b]*Cot[e + f*x]*EllipticF[ArcSin[(Sqrt[c + d]*Sqrt[a + b*Sec[ 
e + f*x]])/(Sqrt[a + b]*Sqrt[c + d*Sec[e + f*x]])], ((a + b)*(c - d))/((a 
- b)*(c + d))]*Sqrt[((b*c - a*d)*(1 - Sec[e + f*x]))/((a + b)*(c + d*Sec[e 
 + f*x]))]*Sqrt[-(((b*c - a*d)*(1 + Sec[e + f*x]))/((a - b)*(c + d*Sec[e + 
 f*x])))]*(c + d*Sec[e + f*x]))/(b*Sqrt[c + d]*(b*c - a*d)*f)
 

3.3.69.3.1 Defintions of rubi rules used

rule 3042
Int[u_, x_Symbol] :> Int[DeactivateTrig[u, x], x] /; FunctionOfTrigOfLinear 
Q[u, x]
 

rule 4470
Int[(csc[(e_.) + (f_.)*(x_)]*Sqrt[csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_)])/Sq 
rt[csc[(e_.) + (f_.)*(x_)]*(d_.) + (c_)], x_Symbol] :> Simp[-2*((a + b*Csc[ 
e + f*x])/(d*f*Sqrt[(a + b)/(c + d)]*Cot[e + f*x]))*Sqrt[(-(b*c - a*d))*((1 
 - Csc[e + f*x])/((c + d)*(a + b*Csc[e + f*x])))]*Sqrt[(b*c - a*d)*((1 + Cs 
c[e + f*x])/((c - d)*(a + b*Csc[e + f*x])))]*EllipticPi[b*((c + d)/(d*(a + 
b))), ArcSin[Sqrt[(a + b)/(c + d)]*(Sqrt[c + d*Csc[e + f*x]]/Sqrt[a + b*Csc 
[e + f*x]])], (a - b)*((c + d)/((a + b)*(c - d)))], x] /; FreeQ[{a, b, c, d 
, e, f}, x] && NeQ[b*c - a*d, 0] && NeQ[a^2 - b^2, 0] && NeQ[c^2 - d^2, 0]
 

rule 4472
Int[csc[(e_.) + (f_.)*(x_)]/(Sqrt[csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_)]*Sqr 
t[csc[(e_.) + (f_.)*(x_)]*(d_.) + (c_)]), x_Symbol] :> Simp[-2*((c + d*Csc[ 
e + f*x])/(f*(b*c - a*d)*Rt[(c + d)/(a + b), 2]*Cot[e + f*x]))*Sqrt[(b*c - 
a*d)*((1 - Csc[e + f*x])/((a + b)*(c + d*Csc[e + f*x])))]*Sqrt[(-(b*c - a*d 
))*((1 + Csc[e + f*x])/((a - b)*(c + d*Csc[e + f*x])))]*EllipticF[ArcSin[Rt 
[(c + d)/(a + b), 2]*(Sqrt[a + b*Csc[e + f*x]]/Sqrt[c + d*Csc[e + f*x]])], 
(a + b)*((c - d)/((a - b)*(c + d)))], x] /; FreeQ[{a, b, c, d, e, f}, x] && 
 NeQ[b*c - a*d, 0] && NeQ[a^2 - b^2, 0] && NeQ[c^2 - d^2, 0]
 

rule 4473
Int[csc[(e_.) + (f_.)*(x_)]^2/(Sqrt[csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_)]*S 
qrt[csc[(e_.) + (f_.)*(x_)]*(d_.) + (c_)]), x_Symbol] :> Simp[-a/b   Int[Cs 
c[e + f*x]/(Sqrt[a + b*Csc[e + f*x]]*Sqrt[c + d*Csc[e + f*x]]), x], x] + Si 
mp[1/b   Int[Csc[e + f*x]*(Sqrt[a + b*Csc[e + f*x]]/Sqrt[c + d*Csc[e + f*x] 
]), x], x] /; FreeQ[{a, b, c, d, e, f}, x] && NeQ[b*c - a*d, 0]
 
3.3.69.4 Maple [A] (verified)

Time = 15.93 (sec) , antiderivative size = 262, normalized size of antiderivative = 0.66

method result size
default \(-\frac {2 \sqrt {c +d \sec \left (f x +e \right )}\, \sqrt {a +b \sec \left (f x +e \right )}\, \left (\operatorname {EllipticF}\left (\sqrt {\frac {a -b}{a +b}}\, \left (-\cot \left (f x +e \right )+\csc \left (f x +e \right )\right ), \sqrt {\frac {\left (a +b \right ) \left (c -d \right )}{\left (a -b \right ) \left (c +d \right )}}\right )-2 \operatorname {EllipticPi}\left (\sqrt {\frac {a -b}{a +b}}\, \left (-\cot \left (f x +e \right )+\csc \left (f x +e \right )\right ), \frac {a +b}{a -b}, \frac {\sqrt {\frac {c -d}{c +d}}}{\sqrt {\frac {a -b}{a +b}}}\right )\right ) \sqrt {\frac {d +c \cos \left (f x +e \right )}{\left (c +d \right ) \left (\cos \left (f x +e \right )+1\right )}}\, \sqrt {\frac {b +a \cos \left (f x +e \right )}{\left (a +b \right ) \left (\cos \left (f x +e \right )+1\right )}}\, \left (\cos \left (f x +e \right )^{2}+\cos \left (f x +e \right )\right )}{f \sqrt {\frac {a -b}{a +b}}\, \left (d +c \cos \left (f x +e \right )\right ) \left (b +a \cos \left (f x +e \right )\right )}\) \(262\)

input
int(sec(f*x+e)^2/(a+b*sec(f*x+e))^(1/2)/(c+d*sec(f*x+e))^(1/2),x,method=_R 
ETURNVERBOSE)
 
output
-2/f/((a-b)/(a+b))^(1/2)*(c+d*sec(f*x+e))^(1/2)*(a+b*sec(f*x+e))^(1/2)*(El 
lipticF(((a-b)/(a+b))^(1/2)*(-cot(f*x+e)+csc(f*x+e)),((a+b)*(c-d)/(a-b)/(c 
+d))^(1/2))-2*EllipticPi(((a-b)/(a+b))^(1/2)*(-cot(f*x+e)+csc(f*x+e)),(a+b 
)/(a-b),((c-d)/(c+d))^(1/2)/((a-b)/(a+b))^(1/2)))*(1/(c+d)*(d+c*cos(f*x+e) 
)/(cos(f*x+e)+1))^(1/2)*(1/(a+b)*(b+a*cos(f*x+e))/(cos(f*x+e)+1))^(1/2)/(d 
+c*cos(f*x+e))/(b+a*cos(f*x+e))*(cos(f*x+e)^2+cos(f*x+e))
 
3.3.69.5 Fricas [F(-1)]

Timed out. \[ \int \frac {\sec ^2(e+f x)}{\sqrt {a+b \sec (e+f x)} \sqrt {c+d \sec (e+f x)}} \, dx=\text {Timed out} \]

input
integrate(sec(f*x+e)^2/(a+b*sec(f*x+e))^(1/2)/(c+d*sec(f*x+e))^(1/2),x, al 
gorithm="fricas")
 
output
Timed out
 
3.3.69.6 Sympy [F]

\[ \int \frac {\sec ^2(e+f x)}{\sqrt {a+b \sec (e+f x)} \sqrt {c+d \sec (e+f x)}} \, dx=\int \frac {\sec ^{2}{\left (e + f x \right )}}{\sqrt {a + b \sec {\left (e + f x \right )}} \sqrt {c + d \sec {\left (e + f x \right )}}}\, dx \]

input
integrate(sec(f*x+e)**2/(a+b*sec(f*x+e))**(1/2)/(c+d*sec(f*x+e))**(1/2),x)
 
output
Integral(sec(e + f*x)**2/(sqrt(a + b*sec(e + f*x))*sqrt(c + d*sec(e + f*x) 
)), x)
 
3.3.69.7 Maxima [F]

\[ \int \frac {\sec ^2(e+f x)}{\sqrt {a+b \sec (e+f x)} \sqrt {c+d \sec (e+f x)}} \, dx=\int { \frac {\sec \left (f x + e\right )^{2}}{\sqrt {b \sec \left (f x + e\right ) + a} \sqrt {d \sec \left (f x + e\right ) + c}} \,d x } \]

input
integrate(sec(f*x+e)^2/(a+b*sec(f*x+e))^(1/2)/(c+d*sec(f*x+e))^(1/2),x, al 
gorithm="maxima")
 
output
integrate(sec(f*x + e)^2/(sqrt(b*sec(f*x + e) + a)*sqrt(d*sec(f*x + e) + c 
)), x)
 
3.3.69.8 Giac [F]

\[ \int \frac {\sec ^2(e+f x)}{\sqrt {a+b \sec (e+f x)} \sqrt {c+d \sec (e+f x)}} \, dx=\int { \frac {\sec \left (f x + e\right )^{2}}{\sqrt {b \sec \left (f x + e\right ) + a} \sqrt {d \sec \left (f x + e\right ) + c}} \,d x } \]

input
integrate(sec(f*x+e)^2/(a+b*sec(f*x+e))^(1/2)/(c+d*sec(f*x+e))^(1/2),x, al 
gorithm="giac")
 
output
integrate(sec(f*x + e)^2/(sqrt(b*sec(f*x + e) + a)*sqrt(d*sec(f*x + e) + c 
)), x)
 
3.3.69.9 Mupad [F(-1)]

Timed out. \[ \int \frac {\sec ^2(e+f x)}{\sqrt {a+b \sec (e+f x)} \sqrt {c+d \sec (e+f x)}} \, dx=\int \frac {1}{{\cos \left (e+f\,x\right )}^2\,\sqrt {a+\frac {b}{\cos \left (e+f\,x\right )}}\,\sqrt {c+\frac {d}{\cos \left (e+f\,x\right )}}} \,d x \]

input
int(1/(cos(e + f*x)^2*(a + b/cos(e + f*x))^(1/2)*(c + d/cos(e + f*x))^(1/2 
)),x)
 
output
int(1/(cos(e + f*x)^2*(a + b/cos(e + f*x))^(1/2)*(c + d/cos(e + f*x))^(1/2 
)), x)